@import "@/assets/styles/variables.less";

:root {
  font-family: 'PingFangSC-Medium', 'segoe ui', sans-serif!important;
  line-height: 1.5;
  font-weight: 400;
  // color-scheme: light dark;
  color: rgba(255, 255, 255, 0.87);
  background-color: #242424;

  font-synthesis: none;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  --drag-preview-opacity: 0.1;
}

a {
  color: #167FFF;
  text-decoration: inherit;
}
a:hover {
  color: #167FFF;
}

html, body {
	width: 100%;
	height: 100%;
	margin: 0;
	overflow: hidden;
	color: var(--text-color);
}
html, body * {
	font-family: 'PingFangSC-Medium', 'segoe ui', sans-serif!important;
    box-sizing: border-box;
}
body {
  margin: 0;
  display: flex;
  place-items: center;
}

#nprogress {
	
	// .bar,.spinner {
	// 	display: none;
	// }

	.custom-nprogress {
		width: 100%;
		height: 100%;
		display: flex;
		justify-content: center;
	    align-items: center;
	    flex-direction: column;

		position: fixed;
		top: 0px;
		left: 0px;
		right: 0px;
		overflow: hidden;
		width: 100%;
		height: 100%;
		z-index: 10000;
	    background-color: #f4f7f9;

		.logo {
			width: 50px;
			height: 50px;
		}

		.title {
			color: #555;
			display: flex;
	        margin-top: 30px;
	        font-size: 30px;
	        justify-content: center;
	        align-items: center;
		}

		.dots {
			.dot {
		        position: relative;
		        display: inline-block;
		        width: 48px;
		        height: 48px;
		        margin-top: 30px;
		        font-size: 32px;
		        transform: rotate(45deg);
		        box-sizing: border-box;
		        animation: antRotate 1.2s infinite linear;
		    }

		    .dot i {
		        position: absolute;
		        display: block;
		        width: 20px;
		        height: 20px;
		        background-color: #0065cc;
		        border-radius: 100%;
		        opacity: 0.3;
		        transform: scale(0.75);
		        animation: antSpinMove 1s infinite linear alternate;
		        transform-origin: 50% 50%;
		    }

		    .dot i:nth-child(1) {
		        top: 0;
		        left: 0;
		    }

		    .dot i:nth-child(2) {
		        top: 0;
		        right: 0;
		        -webkit-animation-delay: 0.4s;
		        animation-delay: 0.4s;
		    }

		    .dot i:nth-child(3) {
		        right: 0;
		        bottom: 0;
		        -webkit-animation-delay: 0.8s;
		        animation-delay: 0.8s;
		    }

		    .dot i:nth-child(4) {
		        bottom: 0;
		        left: 0;
		        -webkit-animation-delay: 1.2s;
		        animation-delay: 1.2s;
		    }

			@keyframes antRotate {
		        to {
		            -webkit-transform: rotate(405deg);
		            transform: rotate(405deg);
		        }
			}
		    @-webkit-keyframes antRotate {
		        to {
		            -webkit-transform: rotate(405deg);
		            transform: rotate(405deg);
		        }
		    }
		    @keyframes antSpinMove {
		        to {
		            opacity: 1;
		        }
		    }
		    @-webkit-keyframes antSpinMove {
		        to {
		            opacity: 1;
		        }
		    }
		}
	}
}


h1 {
  font-size: 3.2em;
  line-height: 1.1;
}
p {
	margin: 0px;
}
button {
  border-radius: 8px;
  border: 1px solid transparent;
  padding: 0.6em 1.2em;
  font-size: 13px;
  font-weight: 500;
  font-family: inherit;
  background-color: #1a1a1a;
  cursor: pointer;
  transition: border-color 0.25s;
}
button:hover {
  border-color: #167fff;
}
button:focus,
button:focus-visible {
  outline: 4px auto -webkit-focus-ring-color;
}

.card {
  padding: 2em;
}

#app {
  width: 100%;
  height: 100%;
  overflow: hidden;
  font-size: 14px;
}

::-webkit-scrollbar {
    width: 6px;  /* 滚动条的宽度 */
    height: 6px; /* 滚动条的高度 */
}
 
/* 滚动条轨道 */
::-webkit-scrollbar-track {
    background: #f1f1f1; /* 轨道颜色 */
}
 
/* 滚动条滑块 */
::-webkit-scrollbar-thumb {
    background: #888; /* 滑块颜色 */
    border-radius: 10px; /* 滑块圆角 */
}
 
/* 滑块悬停状态 */
::-webkit-scrollbar-thumb:hover {
    background: #555; /* 滑块悬停颜色 */
}

@media (prefers-color-scheme: light) {
  :root {
    color: #213547;
    background-color: #ffffff;
  }
  a:hover {
    color: #167fff;
  }
  button {
    background-color: #f9f9f9;
  }
}

.flex {
	display: flex;
}
.flex-col {
	display: flex;
	flex-direction: column;
}
.items-center {
	align-items: center;
}
.items-start {
	align-items: flex-start;
}
.justify-center {
	justify-content: center;
}

.default-input {
  height: 44px!important;
	padding: 10px;
	border-width: 1px;
  border-style: solid;
	border-color: var(--input-border);
	border-radius: 4px;
	box-shadow: none;
	color: var(--text-color);
	font-size: 13px;
	&:focus,&.ant-input-focused, &.ant-input-affix-wrapper-focused {
		border-inline-end-width: 1px;
		box-shadow: 0 0 0 2px rgba(5, 175, 255, 0.1);
		border-color: var(--focus-border);
	}
	// .el-input__inner {
	// 	font-size: 13px;
	// }
}

.ant-input {
	font-size: 13px;
  	height: 32px;
	border-radius: 2px;
}
.ant-input-affix-wrapper {
	border-radius: 2px;
	.ant-input {
		height: 22px;
	}
}

.ant-btn, .ant-btn.ant-btn-sm {
	border-radius: 2px;
	font-size: 13px;
}

.ant-btn-primary, .ant-btn-primary:active, .ant-btn-primary:focus {
	outline: none;
	&:not(.ant-btn-background-ghost) {
		outline: none;
		background-color: var(--active-color);
	}
}


.ant-dropdown {
	.avatar-menu {
		width: 120px;
		min-width: 120px;
		border-radius: 2px;
		font-size: 12px;
		.ant-dropdown-menu-title-content {
			font-size: 12px;
			.anticon {
				margin-right: 0.25rem;
			}
		}
	}
}

.ant-modal {
	.ant-modal-confirm-title {
		color: #555;
		font-size: 13.5px;
	}
	.ant-modal-content {
		border-radius: 2px;
		color: #555;
		font-size: 13px;
		padding: 0px;
		.ant-modal-header {
			padding: 16px;
			border-bottom: 1px solid rgba(5, 5, 5, 0.06);
			.ant-modal-title {
				color: #555;
				font-size: 13.5px;
				font-weight: 400;
			}
		}
		.ant-modal-body {
			.ant-modal-confirm-body-wrapper {
				padding: 16px;
			}
		}
		
		.ant-modal-footer {
			padding: 8px 16px;
		    border-top: 1px solid rgba(5, 5, 5, 0.06);
		    border-radius: 0 0 2px 2px;
		    margin-top: 0;
		}
	}
	&.ant-modal-confirm {
		.ant-modal-confirm-body {
			.ant-modal-confirm-title {
				color: #555;
				font-size: 13.5px;
			}
			.ant-modal-confirm-title +.ant-modal-confirm-content {
				color: #555;
				font-size: 13px;
			}
		}
	}
	&.sys-modal {
		.ant-modal-content {
			padding: 0px;
			.ant-modal-header {
				padding: 16px;
				// border-bottom: 1px solid rgba(5, 5, 5, 0.06);
				margin-bottom: 0px;
				.anticon {
					font-size: 16px;
				}
			}

			.ant-modal-body {
				padding: 5px 0px;
			}

			.ant-modal-footer {
				padding: 8px 16px;
				border-top: 1px solid rgba(5, 5, 5, 0.06);
			}
		}
		&.border {
			.ant-modal-content {
				.ant-modal-header {
					border-bottom: 1px solid rgba(5, 5, 5, 0.06);
					margin-bottom: 8px;
				}
			}
		}
	}
	&.full-modal {
	    max-width: 100%;
		width: 100% !important;
	    top: 0;
	    padding-bottom: 0;
	    margin: 0;
	  
	  .ant-modal-content {
	    display: flex;
	    flex-direction: column;
	    height: calc(100vh);
	  }
	  .ant-modal-body {
	    flex: 1;
	  }
	}
}

button:focus, button:focus-visible, 
.ant-btn:focus,.ant-btn:focus-visible, 
.ant-btn:not(:disabled):focus-visible, 
svg, 
span, 
span:active, 
span:focus, 
span:focus-visible, 
a:active, 
a:focus, 
a:focus-visible {
	outline: none;
}

.custom-checkbox, .ant-checkbox-wrapper {
	color: #555;
	font-weight: 400;
	font-size: 13px;
	&.ant-checkbox-wrapper:hover .ant-checkbox:after {
		visibility: hidden !important;
	}
	&.ant-checkbox-wrapper:not(.ant-checkbox-wrapper-disabled):hover {
		.ant-checkbox-checked:not(.ant-checkbox-disabled) .ant-checkbox-inner {
			background-color: transparent;
			border-color: #167FFF;
		}
	}
	
	.ant-checkbox-inner {
	    background: transparent;
	    width: 14px;
	    height: 14px;
		border-radius: 2px;
		border: 1px solid #d9d9d9;
		&::after {
			border-color: #167fff;
		}
	}
	.ant-checkbox-checked {
		.ant-checkbox-inner {
			border-color: #167FFF;
		}
	}
}
.ant-popconfirm {
	min-width: 150px;
}

.ant-tooltip {
	.ant-tooltip-inner {
		font-size: 13px;
	}
}

.ant-menu-submenu-popup{
	.ant-menu-sub.ant-menu-vertical {
		border-radius: 2px;
		min-width: 90px;
		.ant-menu-item {
			padding: 0px 10px !important;
			margin: 0px !important;
			height: 36px;
		    line-height: 36px;
		    font-size: 12px;
			width: 100%;
		}
	}
	
}

.ml-2 {
	margin-left: 0.5rem;
}

.ant-table-filter-dropdown {
	.ant-checkbox-wrapper-checked:not(.ant-checkbox-wrapper-disabled):hover .ant-checkbox-inner, 
	.ant-checkbox-checked:not(.ant-checkbox-disabled):hover .ant-checkbox-inner {
		background: transparent !important;
		border-color: #167FFF !important;
	}
	.ant-checkbox-wrapper:hover .ant-checkbox:after {
		visibility: hidden !important;
	}
	.ant-dropdown-menu-item {
		.ant-dropdown-menu-item-selected {
			background-color: none;
		}
	}
	.ant-checkbox-checked {
		.ant-checkbox-inner {
		    border-color: #167FFF;
		    background: transparent;
		    width: 14px;
		    height: 14px;
			border-radius: 2px;
			&::after {
				border-color: #167fff;
			}
		}
	}
}

.ant-popconfirm {
	.ant-popconfirm-message-title {
		font-size: 13.5px;
		color: #555;
	}
}
.ant-popconfirm.custom-popconfirm {
	.ant-popover-inner {
		padding: 0px;
		.ant-popconfirm-message-title {
			margin-inline-start: 0px;
			margin: 0;
			padding: 5px 16px 4px;
			border-bottom: 1px solid rgba(5, 5, 5, 0.06);
			
		}
		.custom-col-1 {
			width: 32px;
			display: flex;
			justify-content: center;
		}
		.ant-popconfirm-description {
			margin-inline-start: 0px;
			
			.list {
				padding: 0px 16px;
				max-height: 220px;
				overflow-y: auto;
				.list-item {
					padding: 5px 0px;
					font-size: 13px;
					display: flex;
					align-items: center;
					justify-content: space-between;
					&.top {
						position: sticky;
						top: 0; /* 触发固定的阈值 */
						background: white;
						z-index: 100;
						padding: 2px 0px;
					}
					&.bottom {
						position: sticky;
						bottom: 0; /* 触发固定的阈值 */
						background: white;
						z-index: 100;
						padding: 2px 0px;
					}
				}
			}
		}
		.ant-popconfirm-buttons {
			padding: 5px 16px;
		}
	}
	
}

.ant-select {
	.ant-select-selector {
		border-radius: 2px;
	}
	&.ant-select-single.ant-select-sm {
		.ant-select-selector {
			font-size: 13px;
			border-radius: 2px;
		}
	}
	.ant-select-selection-item {
		font-size: 13px;
		color: #555;
	}
}
.ant-select-dropdown {
	.ant-select-item {
		color: #555;
		font-size: 13px;
	}
	.ant-select-item-option-selected:not(.ant-select-item-option-disabled) {
		color: #555;
		font-size: 13px;
		font-weight: 400;
	}
	&.ant-cascader-dropdown {
		.ant-cascader-menu-item {
			color: #555;
			font-size: 13px;
			font-weight: 400;
		}
		.ant-cascader-menu-item-active:not(.ant-cascader-menu-item-disabled),.ant-cascader-menu-item-active:not(.ant-cascader-menu-item-disabled):hover {
			border-radius: 2px;
		}
	}
}

.ant-picker-dropdown {
	.ant-picker-cell {
		&.ant-picker-cell-in-view {
			color: #555;
			font-size: 13px;
		}
		.ant-picker-cell-inner {
			font-size: 13px;
		}
	}
	.ant-picker-header, .ant-picker-body {
		.ant-picker-content th {
			color: #555;
			font-size: 13px;
		}
	}
}
.ql-editor {
	color: #555;
	font-size: 13px;
}
/*
.ant-picker-dropdown {
	color: #555;
	font-size: 13px;
	.ant-picker-header, .ant-picker-cell-in-view:not(.ant-picker-cell-selected) {
		font-size: 13px;
		color: #555;
	}
	 .ant-picker-date-panel {
		.ant-picker-content {
			th, td, .ant-picker-cell-in-view:not(.ant-picker-cell-selected) {
				font-size: 13px;
				color: #555;
			}
		}
	 }
}*/

.ant-form {
	.ant-form-item {
		.ant-form-item-label >label {
			font-size: 13px;
			color: #555;
		}
	}
}
.ant-picker {
	border-radius: 2px;
	font-size: 13px;
	color: #555;
	.ant-picker-input >input {
		font-size: 13px;
		color: #555;
	}
}

.ant-dropdown {
	.custom-menu {
		&.ant-dropdown-menu {
			.ant-dropdown-menu-item, .ant-dropdown-menu-item, .ant-dropdown-menu-submenu .ant-dropdown-menu .ant-dropdown-menu-submenu-title {
				font-size: 13px;
				color: #555;
				&:hover {
					color: rgba(0, 0, 0, 0.88);
				}
			}
		}
	}
}
.w-full {
	width: 100%;
}
.min-h-22 {
	min-height: 22px;
}
.overflow-ellipsis {
	overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    word-break: keep-all;
}

.custor-pointer {
	cursor: pointer;
}

.ant-tooltip {
	.ant-tooltip-arrow {
		&:before {
			background-color: #e1f0f9;
		}
	}
	.ant-tooltip-inner {
		background-color: #e1f0f9;
		color: #555;
		font-size: 13px;
	}
}

.ql-toolbar {
	&.ql-snow {
		.ql-stroke {
			stroke-width: 1;
			stroke: #555;
		}
		.ql-fill, .ql-stroke.ql-fill {
			fill: #555;
		}
	}
}

.is_hide {
	display: none;
}

.ant-tabs-dropdown {
	.ant-tabs-dropdown-menu-vertical {
		background: var(--sideBarBg);
		.ant-tabs-dropdown-menu-title-content {
			color: rgba(255, 255, 255, 0.65);
			.title {
				margin-inline-start: 10px;
			}
			.ant-tabs-dropdown-menu-item-remove {
				padding: 0px;
				color: rgba(255, 255, 255, 0.65);
			}
		}
		
	}
}

.ant-input-search >.ant-input-group >.ant-input-group-addon:last-child .ant-input-search-button {
	border-radius: 0px 2px 2px 0px;
}

.mr-8 {
	margin-right: 8px;
}

.ant-tree-dragging {
  opacity: 0.3 !important;
  background: none !important;
  color: transparent !important;
  box-shadow: none !important;
  border: none !important;
}
.ant-tree-node-draggable {
  opacity: 0.3 !important;
}